import Layout from '@/layout'

const employeeRouter = {
  path: '/employee',
  component: Layout,
  redirect: '/employee/table',
  name: 'Employee',
  meta: {
    title: '员工管理'
  },
  children: [
    {
      path: 'table',
      component: () => import('@/views/employee/table'),
      name: 'EmployeeTable',
      meta: { title: '员工列表', noCache: false }
    },
    {
      path: 'create',
      component: () => import('@/views/employee/form'),
      name: 'EmployeeCreate',
      meta: { title: '新增员工', noCache: false }
    },
    {
      path: 'edit/:id',
      component: () => import('@/views/employee/form'),
      name: 'EmployeeEdit',
      meta: { title: '编辑员工', noCache: false },
      hidden: true
    }
  ]
}

export default employeeRouter

